Skip to content

Fix live and queued steering in private Steward conversations - #9185

Merged
loopx-agent merged 5 commits into
mainfrom
codex/steward-app-steering-20261121
Nov 21, 2026
Merged

loopx-agent merged 5 commits into
mainfrom
codex/steward-app-steering-20261121

Conversation

@huangruiteng

@huangruiteng huangruiteng commented Nov 21, 2026 •

Copy link
Copy Markdown
Collaborator

Goal and delivered outcome

The App can now steer the current Codex turn in a private Steward conversation with fresh authorization, either from the composer or from an existing App queue item. In the installed baseline, Command+Enter reached the steering endpoint and returned HTTP 400. The first candidate fixed the composer, but the queue item's Steer action still returned 400 and left its original input queued.

Both App routes now reuse the private conversation source grant and the original Session, portfolio and Turn. Queue insertion reserves the existing text and records adoption in the same native Turn. It keeps the original Web message in history and does not start another FIFO turn. A proven non-delivery leaves the item eligible for FIFO. An unknown native result offers readback of the same operation. Provider-origin items still require their original route. Queue reservation and readback now live in the existing native queue owner. The Chat runtime stays within its existing module budget.

Author declaration

Written by a Codex model agent. Implements the private original-conversation contract in App conversation and async Inbox and the existing typed native steering and FIFO contracts.

Validation

Check Result Evidence
Mac AppKit and exact installed candidate wheel Passed Native Return activated the queue's existing control. The same multiline message entered the exact active native Turn once, preserved its Web source and original queued ID, and was never started separately. A stale target and a proven non-delivery kept the original input available. Exact replay returned the original adoption.
Uncertain native acknowledgement Passed The native peer accepted the item and withheld its acknowledgement. The UI first received HTTP 409. Check insertion returned HTTP 200 after native readback of the saved client ID. The original reservation stayed out of FIFO and only one native steering packet was sent.
Composer and Pinyin Passed Candidate runs used trusted physical macOS keyboard and system Pinyin in AppKit WKWebView. Pinyin confirmation committed text only. Enter, Shift+Enter, idle Command+Enter and active steering retained their original meanings. One composer at 970 and 390 px without horizontal overflow.
Exact-head HTTP and native protocol 46 passed Includes the full queue module and private Steward composer and queued input cases, their retries and refusal after source change, and the existing Feishu native-mention path.
Core and static validation Passed Nine TypeScript queue tests, control-plane type check, repository mypy, Ruff, bilingual RFC diff check, semantic vocabulary smoke and change-quality qualification.

Tested head 1f3fb7a2969bb81b2fd20f92bb5d0629dd9f4234. Candidate wheel SHA-256 44821dfd4e828e3e341305b75bb09821e202fee2e43230395e2bcb47e1022229. The AppKit runs used the package's local backend and isolated state with synthetic Feishu and Codex peers. Independent review and hosted checks apply to this head. Formal Desktop and live Feishu acceptance remain open.

Hosted checks and base comparison

The published review approved 1f3fb7a. Its isolated HTTP coverage checked exact-turn delivery, retry, provenance, authorization and the original queue. The installed App and live Feishu still need separate validation.

  • Frontstage Pages stopped at the same runtime-guide link warning reproduced on main at 23dacd5. The standalone link repair passed its hosted Pages build. A local Python 3.11 strict build of this PR's source with that single link correction also passed, and the generated link resolved to the original GitHub guide. This PR's Pages run
  • The hosted Ark and MemT lanes failed in test_managed_start_interruption_preserves_reservation_and_attempt at the assertion that admission must refuse the changed plan after the interrupted start. Isolated local runs reproduced the File and SQLite failures on both 23dacd5 and 1f3fb7a. The cases passed on the parent of #9047 and failed on its merged commit. The fixture showed one host attempt after the changed plan on both current trees. This reproduces the shared failure locally. The hosted lanes remain failed. Ark, MemT

Integration with main at 5e2c896

The reviewed head 1f3fb7a and main at 5e2c896 merge locally without a conflict. On the integrated tree, 58 focused Python tests and nine TypeScript steering tests passed, covering delivery to the original Turn, queue behavior, the existing Feishu mention route, and the new Steward monitor retry and evidence bounds. Main change

The standalone runtime-guide correction also passed a strict MkDocs build on main at 5e2c896. GitHub still reports REVIEW_REQUIRED for the docs PR under the branch rules, which require Code Owner approval and approval by someone other than the last pusher. Docs repair

On main at 3d15059, the candidate merges locally without conflicts. Five focused Python tests passed on the integrated tree, covering the composer and queued routes, the existing private Feishu mention, and Steward pre-host retry and follow-up settlement. Nine TypeScript queue tests also passed.

Native Codex app-server validation

Three local HTTP cases used the same candidate wheel and the native Codex app-server 0.171.0-alpha.13. The composer and queued-input routes each started one native Turn and sent one turn/steer to that Turn. Native item history contained the correction exactly once, with the original Turn and exact client message ID. The isolated inference provider received the correction in one request. The HTTP tests also exercised stale-target and source-authorization refusal.

In the third case, the native host accepted the queued correction and the test withheld its acknowledgement from LoopX. The first HTTP call returned 409 and kept the queue reservation. Reading the same operation after the original Turn completed returned 200. A second read returned the same receipt. The native trace contained one turn/start and one turn/steer across the three HTTP calls, and the original queued entry recorded a single adoption.

A fourth native case started with a synthetic private Feishu message, then advanced to a desktop Turn in the same session. A stale adjustment targeting the completed Turn returned HTTP 409 and left both queued inputs intact. Two simultaneous requests targeting the current Turn returned the same receipt. Native history showed one insertion with the exact client ID, followed by one normal execution of the later queued input. Across the case, the host received three turn/start calls and one turn/steer.

The native host used an isolated workspace and a loopback inference provider. Feishu traffic used the synthetic private source. Formal Desktop and live Feishu acceptance remain open.

Recovery across a new backend process

The exact wheel accepted one queued correction in the native Codex Turn and lost the acknowledgement in the test. A fresh backend process returned HTTP 409 twice for the reserved operation and kept it out of FIFO. A separate read-only native client found the exact persisted item by its original Turn and client ID. The new backend did not use that persisted history to confirm delivery while it lacked an attached adapter.

After the original adapter confirmed the saved operation, another fresh backend process returned the same HTTP 200 receipt twice. The full trace contained one native Turn start and one steering call. Recovery before confirmation still depends on the original adapter in this candidate. The fixture used a synthetic private Feishu source and loopback inference.

Frontend and visual evidence

Presentation impact: none. The existing composer, Steer, and Check insertion controls were exercised on the packaged page. No production conversations were used.

Scope

  • Bug fix and regression coverage
  • DCO sign-off on candidate commits
  • Public-safe diff and evidence

@huangruiteng huangruiteng changed the title Fix Command+Enter in private Steward conversations Fix live and queued steering in private Steward conversations Nov 21, 2026

@loopx-agent loopx-agent left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewer: model_agent · gpt-6.2-sol · OpenAI (runtime_reported, xhigh)

动机 / Motivation

在私聊管家里发现当前执行方向需要纠正时,用户可以用 Command+Enter 将补充发给正在运行的 Codex Turn。 同一个已绑定的私聊正在运行时,在本机 App 直接更正当前 Turn,或把已经排队的 Web 输入送入当前 Turn。旧版直接更正返回 HTTP 400 且未调用 Codex。候选两条路径都返回 200,当前 Turn 各接收一次,历史记录保留 Web 来源。 同一输入重复提交返回原回执。会话授权范围失效时不生成回执,恢复原授权后同一输入送达。飞书、Peer 和其他外部排队输入仍留在原队列。 独立验证使用隔离真实 HTTP 流程、合成 Feishu 和 Codex 适配器。正式安装 Desktop、物理键盘和真实 Feishu 未独立复验。 正式安装环境和真实 Feishu 验收仍由发布流程跟进。

改动思路 / Approach

本机 Web 继续使用现有私聊绑定授权,实际送达与读回由原 Turn 的原生 steering 负责。 复用同一个绑定授权与送达回执,并由现有队列判定控制哪些输入可提升进当前 Turn。 我用同一个隔离私聊和真实本机 HTTP 入口先确认旧故障,再读候选的原生请求、送达回执、原会话历史和授权变化。

具体改动 / Changes

评审精确头 1f3fb7a2969bb81b2fd20f92bb5d0629dd9f4234。候选已经包含目标主干 23dacd5fb449194c6a8d83e9764534cdbdd081b4,精确树和本地整合树一致。改动包含直接输入和 Web 排队输入,共八个文件,新增 254 行、删除 50 行。候选已整合当前主干,队列的预留、送达与读回集中在原有 native queue owner。

  • original-source-guard 从现有绑定加载当前所有者和授权范围,核对原会话,并在写入送达回执和请求 Codex 期间持有原绑定的写入防护。普通服务端路径仍进入已有处理器。 HTTP 入口 私聊授权
  • same-turn-steering 使用已有 ingress ID 去重,以当前 Turn 和原生 Turn ID 为目标。成功读回保留 Web 来源,重复输入只读回原结果。过期回合在发送前拒绝,普通 Enter 的入队逻辑沿用现有实现。队列只提升 Web 输入,已有外部来源仍由原队列处理。手动持有 controller lock 时,两条路径均能完成。回执未确认时,原队列预留保留给同一操作读回;已证实未送达时可回到 FIFO。 队列所有者 队列判定 原生送达 既有规范

对主干的风险 / Risks

当前精确头的私聊、直接 steering 和来源对照通过 87 项,现有真实 HTTP 队列用例通过 41 项,TypeScript 队列通过 9 项。Ruff、仓库 mypy 和控制面类型检查通过。 用隔离会话替换已保存的授权范围,真实 HTTP 返回 400,零回执、零发送。恢复原范围后,以同一 ingress ID 提交返回 200,历史中只有一条更正。过期 Turn、所有者不可用及绑定撤销均有拒绝验证。隔离的真实 HTTP 测试中,三种非 Web 来源各返回 409,原队列逐字段相同,发送次数为零。候选沿用普通聊天和 Feishu 的现有入口。正式安装 Desktop、物理键盘和真实 Feishu 未独立复验。未查询托管 CI。

我的整体评价 / Verdict

APPROVE。 当前精确提交恢复本机私聊的原生更正和 Web 排队输入提升,保留准确读回和去重。授权失效时未进入送达。正式安装 Desktop 与真实 Feishu 仍待验收,部署和合并资格继续按独立流程处理。

English verdict: APPROVE at 1f3fb7a2969bb81b2fd20f92bb5d0629dd9f4234. The local private Steward request steers direct or queued Web text into the exact native turn once, preserves source provenance and leaves other queued input untouched. Installed Desktop and live Feishu remain unverified in this review.

@loopx-agent
loopx-agent merged commit c930281 into main Nov 21, 2026
52 of 66 checks passed
@loopx-agent
loopx-agent deleted the codex/steward-app-steering-20261121 branch November 21, 2026 13:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants